projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
80951f7
)
Fix event memory leak on Haiku
author
Po Lu
<luangruo@yahoo.com>
Wed, 11 May 2022 06:56:43 +0000
(06:56 +0000)
committer
Po Lu
<luangruo@yahoo.com>
Wed, 11 May 2022 06:56:43 +0000
(06:56 +0000)
* src/haikuterm.c (haiku_read_socket): Allocate event buffer on
the stack.
src/haikuterm.c
patch
|
blob
|
history
diff --git
a/src/haikuterm.c
b/src/haikuterm.c
index a7403314823d83d244c5e0b312bdc66b1b88b068..ec6a8f0cea17a7874ac1c60662e0a3dbcd5ad346 100644
(file)
--- a/
src/haikuterm.c
+++ b/
src/haikuterm.c
@@
-3007,11
+3007,10
@@
haiku_read_socket (struct terminal *terminal, struct input_event *hold_quit)
message_count = 0;
button_or_motion_p = 0;
do_help = 0;
- buf = NULL;
+
+ buf = alloca (200);
block_input ();
- if (!buf)
- buf = xmalloc (200);
haiku_read_size (&b_size, false);
while (b_size >= 0)
{